<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>多层表头</title>
<!--框架必需start-->
<script type="text/javascript" src="../../libs/js/jquery.js"></script>
<script type="text/javascript" src="../../libs/js/language/cn.js"></script>
<script type="text/javascript" src="../../libs/js/framework.js"></script>
<link href="../../libs/css/import_basic.css" rel="stylesheet" type="text/css"/>
<link rel="stylesheet" type="text/css" id="skin" prePath="../../"/>
<link rel="stylesheet" type="text/css" id="customSkin"/>
<!--框架必需end-->

<!--数据表格start-->
<script src="../../libs/js/table/quiGrid.js" type="text/javascript"></script>
<!--数据表格end-->
<style>
 .headerGroup{
    background: url(../../sample_html/report/head-group2.png) no-repeat;
    width: 181px;
    height: 90px;
    position: absolute;
    left: 11px;
    top:7px;
    z-index: 10;
 } 
</style>
</head>
<body>
  <div class="page_content">
  <div class="headerGroup"></div>
	<div id="maingrid"></div>
  </div>
<script type="text/javascript">
		 var testData={"form.paginate.pageNo":1,"form.paginate.totalRows":13,"rows":[
      {"col1":"饮料","rows":[{
                    "col2": "苹果汁",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "牛奶",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "汽水",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "啤酒",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "蜜桃汁",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "绿茶",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "运动饮料",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "柳橙汁",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "矿泉水",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "苏打水",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "浓缩咖啡",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "柠檬汁",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "小计",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    }
                ]},
                {"col1":"特制品","rows":[
                    {
                    "col2": "海鲜粉",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "沙茶",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "烤肉酱",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "猪肉干",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "鸡精",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    },
                    {
                    "col2": "小计",
                    "col3": "3539.70",
                    "col4": "183.60",
                    "col5": "1332.00",
                    "col6": "3920.40",
                    "col7": "1332.00",
                    "col8": "730.80",
                    "col9": "0.00",
                    "col10": "9706.50",
                    "col11": "1332.00",
                    "col12": "3920.40",
                    "col13": "1332.00",
                    "col14": "730.80",
                    "col15": "0.00",
                    "col16": "9706.50",
                    "col17": "3539.70",
                    "col18": "183.60",
                    "col19": "1332.00",
                    "col20": "3920.40",
                    "col21": "1332.00",
                    "col22": "730.80",
                    "col23": "0.00",
                    "col24": "9706.50"
                    }
                ]}
      ]}
       

       //数据表格
    var g;
        
    function initComplete(){
    	 g = $("#maingrid").quiGrid({
                columns: [ 
                  {  display: '产品',name: 'col1', width: 100, isSort:false,frozen:true},
                  { display: '细分', name: 'col2',width: 80,frozen:true},
                  { display: '按地区统计', columns: [
                    { display: '华北', name: 'col3', width: 80 },
                    { display: '华东', name: 'col4', width: 80 },
                    { display: '东北', name: 'col5', width: 80},
                    { display: '华中', name: 'col6', width: 80},
                    { display: '华南', name: 'col7', width: 80},
                    { display: '西南', name: 'col8', width: 80},
                    { display: '西北', name: 'col9', width: 80},
                    { display: '小计', name: 'col10', width: 80}
                    ]},
                  { display: '按供应商统计', columns: [
                    { display: '佳佳乐', name: 'col11', width: 80 },
                    { display: '康富食品', name: 'col12', width: 80 },
                    { display: '妙生', name: 'col13', width: 80},
                    { display: '为全', name: 'col14', width: 80},
                    { display: '日正', name: 'col15', width: 80},
                    { display: '小计', name: 'col16', width: 80}
                    ]},
                  { display: '按雇员统计', columns: [
                    { display: '赵军', name: 'col17', width: 80 },
                    { display: '卢浩天', name: 'col18', width: 80 },
                    { display: '郑建杰', name: 'col19', width: 80},
                    { display: '李芳', name: 'col20', width: 80},
                    { display: '张雪眉', name: 'col21', width: 80},
                    { display: '张颖', name: 'col22', width: 80},
                    { display: '刘英玫', name: 'col23', width: 80},
                    { display: '小计', name: 'col24', width: 80}
                    ]}
                ], 
                data:testData, 
                pageSize: 10, sortName: 'name',
                height: '100%', width:"100%",multihead:true,usePager:false,rownumbers:false,checkbox:false,multiBody:true
            });
    }
    function pertonum(stringObj){
      var newstr=stringObj.replace(/%/, "");
      return Number(newstr);
    }
          
    </script>		
</body>
</html>